Scala actors : Unifying thread - based and event - based programming Philipp
نویسندگان
چکیده
There is an impedance mismatch between message-passing concurrency and virtual machines, such as the JVM. VMs usually map their threads to heavyweight OS processes. Without a lightweight process abstraction, users are often forced to write parts of concurrent applications in an event-driven style which obscures control flow, and increases the burden on the programmer. In this paper we show how thread-based and event-based programming can be unified under a single actor abstraction. Using advanced abstraction mechanisms of the Scala programming language, we implement our approach on unmodified JVMs. Our programming model integrates well with the threading model of the underlying VM.
منابع مشابه
Scala Actors: Unifying thread-based and event-based programming
There is an impedance mismatch between message-passing concurrency and virtual machines, such as the JVM. VMs usually map their threads to heavyweight OS processes. Without a lightweight process abstraction, users are often forced to write parts of concurrent applications in an event-driven stylewhich obscures control flow, and increases the burden on the programmer. In this paper we show how t...
متن کاملActors That Unify Threads and Events
There is an impedance mismatch between message-passing concurrency and virtual machines, such as the JVM. VMs usually map their threads to heavyweight OS processes. Without a lightweight process abstraction, users are often forced to write parts of concurrent applications in an event-driven style which obscures control flow, and increases the burden on the programmer. In this paper we show how ...
متن کاملAn Object-Oriented Programming Model for Event-Based Actors
Actors are concurrent processes which communicate through asynchronous message passing. Most existing actor languages and libraries implement actors using virtual machine or operating system threads. The resulting actor abstractions are rather heavyweight, both in terms of memory consumption and synchronization. Consequently, their systems are not suited for resource-constrained devices or high...
متن کاملReactive Programming using the Algebra of Communicating Processes
R&D on reactive programming is growing and this has delivered quite many language constructs, libraries and tools. Scala programmers can use threads, timers, actors, futures, promises, observables, the async construct, and others. Still it seems to us that the state of the art is not mature: reactive programming is relatively hard, and confidence in correct operation depends mainly on extensive...
متن کاملA Type-Based Foundation for Closure-Passing in the Age of Concurrency and Distribution
Functional programming (FP) is regularly touted as the way forward for bringing parallel, concurrent, and distributed programming to the mainstream. However, despite this established viewpoint, reliably distributing function closures over a network, or using them in concurrent environments nonetheless remains a challenge across FP and OO languages. Our work on Spores takes a step towards more p...
متن کامل